package com.zzedu.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.zzedu.domain.ZzStuLog;
import com.zzedu.dto.ZzStuLogDTO;
import com.zzedu.mapper.ZzStuLogMapper;
import com.zzedu.service.IZzStuLogService;
import org.springframework.stereotype.Service;
/**
 * 学生续费、分班日志Service业务层处理
 * 
 * @author Mr.Wang
 * @date 2025-06-08
 */
@Service
public class ZzStuLogServiceImpl extends ServiceImpl<ZzStuLogMapper,ZzStuLog> implements IZzStuLogService
{

    @Override
    public LambdaQueryWrapper<ZzStuLog> buildQuery(ZzStuLogDTO zzStuLog) {
        LambdaQueryWrapper<ZzStuLog> lambdaQueryWrapper = Wrappers.lambdaQuery();
        lambdaQueryWrapper.eq(null!=zzStuLog.getStuId(), ZzStuLog::getStuId, zzStuLog.getStuId());
        lambdaQueryWrapper.eq(null!=zzStuLog.getAction(), ZzStuLog::getAction, zzStuLog.getAction());
        lambdaQueryWrapper.eq(null!=zzStuLog.getClzzId(), ZzStuLog::getClzzId, zzStuLog.getClzzId());
        lambdaQueryWrapper.eq(null!=zzStuLog.getOper(), ZzStuLog::getOper, zzStuLog.getOper());
        lambdaQueryWrapper.orderByDesc(ZzStuLog::getId);
        return lambdaQueryWrapper;
    }
}